-
Notifications
You must be signed in to change notification settings - Fork 929
fix: Improve samtools flagstat stub to generate realistic output #9064
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- Replace empty touch command with proper flagstat format in stub - Include realistic read counts and mapping statistics - Ensure stub output matches expected flagstat format for parsing - Critical for pipelines that parse flagstat files for scale factors - Enables proper testing of downstream processes in stub workflows The previous stub created empty files that caused parsing failures when processes attempted to extract mapped read counts from flagstat output. This change provides realistic flagstat content that matches the format of actual samtools flagstat output.
34785f4 to
e396813
Compare
pinin4fjords
approved these changes
Sep 15, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! I'll give it the green tick so you can merge once the tests pass
- Regenerate snapshots to match current samtools version (1.22.1) - Fix versions.yml checksum mismatch - Ensure tests pass with updated container versions
- Update subworkflow snapshots to match realistic flagstat content - Fix stub test failures caused by empty file → realistic content change - All flagstat checksums updated from d41d8cd98f00b204e9800998ecf8427e to 67394650dbae96d1a4fcc70484822159 - Ensures consistency between module and subworkflow test expectations
- Update versions.yml checksums to match CI Docker environment - Use bdc0bfb2b0542580e7cd65e80d8570bc instead of 108a155f2d4a99f50bf3176904208d27 - Keep realistic flagstat content checksums (67394650dbae96d1a4fcc70484822159 for stub) - Ensures tests pass in both local and CI environments
- Regenerate snapshots using Docker containers to match CI environment - All 6 subworkflow tests pass with updated version checksums - Ensures consistency between local and CI test environments
chaochaowong
pushed a commit
to chaochaowong/modules
that referenced
this pull request
Sep 30, 2025
…core#9064) * fix: Improve samtools flagstat stub to generate realistic output - Replace empty touch command with proper flagstat format in stub - Include realistic read counts and mapping statistics - Ensure stub output matches expected flagstat format for parsing - Critical for pipelines that parse flagstat files for scale factors - Enables proper testing of downstream processes in stub workflows The previous stub created empty files that caused parsing failures when processes attempted to extract mapped read counts from flagstat output. This change provides realistic flagstat content that matches the format of actual samtools flagstat output. * test: Update samtools flagstat snapshots with current versions - Regenerate snapshots to match current samtools version (1.22.1) - Fix versions.yml checksum mismatch - Ensure tests pass with updated container versions * test: Update bam_stats_samtools snapshots for improved flagstat stub - Update subworkflow snapshots to match realistic flagstat content - Fix stub test failures caused by empty file → realistic content change - All flagstat checksums updated from d41d8cd98f00b204e9800998ecf8427e to 67394650dbae96d1a4fcc70484822159 - Ensures consistency between module and subworkflow test expectations * test: Fix samtools flagstat snapshots for CI environment - Update versions.yml checksums to match CI Docker environment - Use bdc0bfb2b0542580e7cd65e80d8570bc instead of 108a155f2d4a99f50bf3176904208d27 - Keep realistic flagstat content checksums (67394650dbae96d1a4fcc70484822159 for stub) - Ensures tests pass in both local and CI environments * test: Update bam_stats_samtools snapshots with Docker profile - Regenerate snapshots using Docker containers to match CI environment - All 6 subworkflow tests pass with updated version checksums - Ensures consistency between local and CI test environments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes flagstat stub to generate realistic output instead of empty files.
This resolves parsing failures in stub workflows when processes extract mapped read counts from flagstat output for scale factor calculations.
Related to nf-core/chipseq#470 where this issue was first encountered during bedtools genomecov refactoring.